cross product tricks in ratio